Passer au contenu principal
POST
/
public
/
v1
/
campaign-service
/
campaigns
/
exclusive-banner
[BETA] Create exclusive banner campaign.
curl --request POST \
  --url https://api.topsort.com/public/v1/campaign-service/campaigns/exclusive-banner \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "startDate": "2023-11-07T05:31:56Z",
  "endDate": "2023-11-07T05:31:56Z",
  "exclusivityPrice": 123,
  "bids": [
    {
      "target": {
        "id": "<string>",
        "type": "product"
      },
      "amount": "<unknown>",
      "location": "Santiago",
      "trigger": {
        "type": "<string>",
        "value": {
          "words": [
            "<string>"
          ],
          "matchType": "exact"
        }
      },
      "triggers": [],
      "formatProperties": {
        "bannerAssets": [
          {
            "dimensions": {
              "width": 123,
              "height": 123
            },
            "url": "<string>",
            "contentType": "image/png",
            "size": 123,
            "assetId": "asset_01j713j64yfsvtj4bs3ccpy5ca",
            "content": {},
            "jsonTemplateId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
          }
        ],
        "slotId": "<string>",
        "adFormat": "<string>",
        "deviceType": "desktop"
      }
    }
  ],
  "isActive": true,
  "externalCampaignId": "<string>",
  "isAutoTrigger": false,
  "position": 1,
  "walletId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "impressionsThreshold": 123,
  "exclusivityPercentage": 123,
  "status": "pending",
  "productIds": [
    "<string>"
  ]
}
'
{
  "name": "<string>",
  "marketplaceId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "campaignId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "exclusivityPrice": 123,
  "chargeType": "DAILY",
  "campaignType": "manual",
  "adFormat": "<string>",
  "vendorId": "<string>",
  "walletId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "isActive": true,
  "externalCampaignId": "<string>",
  "isAutoTrigger": false,
  "startDate": "2023-11-07T05:31:56Z",
  "endDate": "2023-11-07T05:31:56Z",
  "bidType": "exclusive",
  "createdBy": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "position": 1,
  "status": "pending",
  "impressionsThreshold": 123,
  "exclusivityPercentage": 123
}

Autorisations

Authorization
string
header
requis

A valid API key generated in Topsort's UI.

Paramètres de requête

vendor_id
string
requis

The ID of the vendor.

Minimum string length: 1

Corps

application/json

The request body for creating an exclusive banner campaign.

name
string
requis

The name of the campaign.

Minimum string length: 1
Exemple:

"Bola-Bola Ad campaign"

startDate
string<date-time>
requis

When should the campaign start. If the start date is in the past, it will be set to the current date.

endDate
string<date-time>
requis

When should the campaign stop. Must be greater than start date.

exclusivityPrice
integer
requis

The price to pay daily for the campaign to run.

bids
BidCreate · object[]
requis

An array of bids for this campaign.

Minimum array length: 1
isActive
boolean
défaut:true

Whether the campaign should be activated upon creation.The campaign will start when this is set and the start_date has passed.

externalCampaignId
string | null

The external ID of the campaign in the marketplace. Must be unique per marketplace and format combination.

isAutoTrigger
boolean
défaut:false

Whether the campaign is auto-triggered.

position
integer
défaut:1

The rank the ad will have in the auction

Plage requise: 1 <= x <= 20
walletId
string<uuid> | null

The uuid of the wallet to be used with this campaign.

impressionsThreshold
integer | null

Impressions allowed for the campaign before it is stopped.

exclusivityPercentage
number | null

Percentage of auctions the campaign will be exclusive in.

status
enum<string>
défaut:pending

For an exclusive banner campaign, its initial review status.

Options disponibles:
approved,
pending,
rejected
productIds
string[]

The product IDs to be used in the exclusive banner campaign. When provided, the assets will be associated to the given product IDs.

Maximum array length: 200

Réponse

Successful Response

Model that represents an Exclusive Banner Campaign.

name
string
requis

The name of the campaign.

Minimum string length: 1
Exemple:

"Bola-Bola Ad campaign"

marketplaceId
string<uuid>
requis

The ID of the marketplace.

campaignId
string<uuid>
requis

The ID of the campaign.

exclusivityPrice
integer
requis

The price to pay daily for the campaign to run.

chargeType
enum<string>
requis

How exclusive campaigns are going to be charged, only daily is allowed.

Options disponibles:
DAILY
campaignType
enum<string>
requis

The bidding method for the campaign.

Options disponibles:
manual,
autobidding,
exclusive
adFormat
string
requis

The ad format of the campaign. Can be exclusive_banner.

Allowed value: "exclusive_banner"
Exemple:

"exclusive_banner"

vendorId
string
requis

The marketplace's ID of the vendor.

walletId
string<uuid>
requis

The uuid of the wallet to be used with this campaign.

isActive
boolean
défaut:true

Whether the campaign should be activated upon creation.The campaign will start when this is set and the start_date has passed.

externalCampaignId
string | null

The external ID of the campaign in the marketplace.

isAutoTrigger
boolean
défaut:false

Whether the campaign is auto-triggered.

startDate
string<date-time>

Date when to start the campaign, specified in RFC 3339, if not set that campaign will start immediately after the campaign creation. Must include the Timezone definition.If the start date is in the past, it will be set to the current date.

endDate
string<date-time>

Date when to stop the campaign, specified in RFC 3339, if not set the campaign will never stop. This date must be greater than the start date and must be in the future. Must include the Timezone definition.

bidType
string
défaut:exclusive

The bidding type of the campaign.

Allowed value: "exclusive"
createdBy
string<uuid> | null

The ID of the user creating the campaign.

position
integer
défaut:1

The rank the ad will have in the auction

Plage requise: 1 <= x <= 20
status
enum<string>
défaut:pending

For an exclusive banner campaign, its initial review status.

Options disponibles:
approved,
pending,
rejected
impressionsThreshold
integer | null

Impressions allowed for the campaign before it is stopped.

exclusivityPercentage
number | null

Percentage of auctions the campaign will be exclusive in.